home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1995 November / EnigmA AMIGA RUN 02 (1995)(G.R. Edizioni)(IT)[!][issue 1995-11][Skylink CD].iso / earcd / ear / mui23dev.lha / MUI / Developer / Modula / txt / MuiSupport.mod < prev   
Text File  |  1994-06-04  |  2KB  |  88 lines

  1. IMPLEMENTATION MODULE MuiSupport;
  2.  
  3. (*$ NilChk      := FALSE *)
  4. (*$ EntryClear  := FALSE *)
  5. (*$ LargeVars   := FALSE *)
  6. (*$ StackParms  := FALSE *)
  7.  
  8. (* MuiSupport 2.0
  9. ** converted by C.Scholz
  10. **
  11. ** HISTORY :
  12. **
  13. ** 22.10.1993 : changed fail, it now does not use Terminal anymore.
  14. **              Instead it uses Arts.Requester
  15. **              (inspired by Michael Suelman)
  16. **
  17. ** $Log: MuiSupport.mod,v $
  18. # Revision 1.4  1994/02/09  14:50:03  Kochtopf
  19. # Versionsnummer in 2.0 geaendert.
  20. #
  21. # Revision 1.3  1994/02/02  09:37:18  Kochtopf
  22. # app bei fail in VAR-Parameter geaendert.
  23. #
  24. # Revision 1.2  1994/02/01  16:49:10  Kochtopf
  25. # kleine Veraenderungen.
  26. #
  27. **
  28. **
  29. *)
  30.  
  31.  
  32. IMPORT R;
  33. IMPORT MD:MuiD;
  34. IMPORT ML:MuiL;
  35. FROM Arts       IMPORT StrPtr, returnVal, Exit, Requester;
  36. FROM SYSTEM     IMPORT ASSEMBLE, ADDRESS, ADR;
  37. FROM IntuitionD IMPORT IClassPtr;
  38. FROM UtilityD   IMPORT Hook;
  39.  
  40.  
  41. PROCEDURE DoMethod(obj{R.A2} : APTR; msg{R.A1} : APTR);
  42. (*$ EntryExitCode:=FALSE *)
  43.  
  44. BEGIN
  45.  
  46.     ASSEMBLE (  MOVEA.L -4(A2),  A0
  47.                 MOVE.L   8(A0),-(A7)
  48.                 RTS
  49.                 END );
  50.  
  51. END DoMethod;
  52.  
  53. PROCEDURE DOMethod(obj{R.A2} : APTR; msg{R.A1} : APTR) : LONGINT;
  54. (*$ EntryExitCode:=FALSE *)
  55.  
  56. BEGIN
  57.  
  58.     ASSEMBLE (  MOVEA.L -4(A2),  A0
  59.                 MOVE.L   8(A0),-(A7)
  60.                 RTS
  61.                 END );
  62.  
  63. END DOMethod;
  64.  
  65.  
  66.  
  67. (*****************)
  68. (* Fail Function *)
  69. (*****************)
  70.  
  71. PROCEDURE fail(VAR app : APTR; str : ARRAY OF CHAR);
  72.  
  73.     VAR
  74.         Result     : BOOLEAN;
  75.  
  76.     BEGIN
  77.         IF app#NIL THEN ML.mDisposeObject(app); app:=NIL; END;
  78.  
  79.         IF str[0]#0C THEN
  80.                 Result:=Requester(ADR("MUI-Request"),ADR(str),NIL,ADR("Oh..."));
  81.                 Exit(20);
  82.            ELSE
  83.                 Exit(0);
  84.            END;
  85.     END fail;
  86.  
  87. END MuiSupport.
  88.